# 在这里写上你的代码 :-)
from microbit import *
import TM1637
import music


tm = TM1637.TM1637(dio=pin14, clk=pin13)

n = 107
tm.shownum(n)
while True:
    if n % 100 == 0:
        n -= 41
    else:
        n -= 1
    tm.shownum(n)
    if n == 0:
        break
    sleep(100)
music.set_tempo(ticks=4, bpm=120)
music.play(music.BIRTHDAY)
